Set the cell renderer to inert mode to avoid bug #154921. This fixes a
authorMatthias Clasen <matthiasc@src.gnome.org>
Fri, 8 Oct 2004 17:09:18 +0000 (17:09 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Fri, 8 Oct 2004 17:09:18 +0000 (17:09 +0000)
* gtk/gtkfilechooserdefault.c (renderer_edited_cb): Set the cell
renderer to inert mode to avoid bug #154921.  This fixes a crash
which would otherwise occur if the editing is stopped for the second
time.  (#154767, Manuel Baena García)

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkfilechooserdefault.c

index 4ffacbbcde0491f64c949a304a8a789d6947574f..58369375134019ebc530188741976e1429b39e23 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2004-10-08  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkfilechooserdefault.c (renderer_edited_cb): Set the cell 
+       renderer to inert mode to avoid bug #154921.  This fixes a crash
+       which would otherwise occur if the editing is stopped for the second
+       time.  (#154767, Manuel Baena García)
+
        * gtk/gtkdebug.h: 
        * gtk/gtkwidget.c (gtk_widget_size_allocate): Add a new debug
        flag, geometry, to debug size allocation.
index 4ffacbbcde0491f64c949a304a8a789d6947574f..58369375134019ebc530188741976e1429b39e23 100644 (file)
@@ -1,5 +1,10 @@
 2004-10-08  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkfilechooserdefault.c (renderer_edited_cb): Set the cell 
+       renderer to inert mode to avoid bug #154921.  This fixes a crash
+       which would otherwise occur if the editing is stopped for the second
+       time.  (#154767, Manuel Baena García)
+
        * gtk/gtkdebug.h: 
        * gtk/gtkwidget.c (gtk_widget_size_allocate): Add a new debug
        flag, geometry, to debug size allocation.
index 4ffacbbcde0491f64c949a304a8a789d6947574f..58369375134019ebc530188741976e1429b39e23 100644 (file)
@@ -1,5 +1,10 @@
 2004-10-08  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkfilechooserdefault.c (renderer_edited_cb): Set the cell 
+       renderer to inert mode to avoid bug #154921.  This fixes a crash
+       which would otherwise occur if the editing is stopped for the second
+       time.  (#154767, Manuel Baena García)
+
        * gtk/gtkdebug.h: 
        * gtk/gtkwidget.c (gtk_widget_size_allocate): Add a new debug
        flag, geometry, to debug size allocation.
index 4ffacbbcde0491f64c949a304a8a789d6947574f..58369375134019ebc530188741976e1429b39e23 100644 (file)
@@ -1,5 +1,10 @@
 2004-10-08  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkfilechooserdefault.c (renderer_edited_cb): Set the cell 
+       renderer to inert mode to avoid bug #154921.  This fixes a crash
+       which would otherwise occur if the editing is stopped for the second
+       time.  (#154767, Manuel Baena García)
+
        * gtk/gtkdebug.h: 
        * gtk/gtkwidget.c (gtk_widget_size_allocate): Add a new debug
        flag, geometry, to debug size allocation.
index 22ee3fa141a269e576b01aa998a551ae59ba0a2c..11ccc420be368063fc422a7d2cfb77b2b057a446 100644 (file)
@@ -1627,7 +1627,10 @@ renderer_edited_cb (GtkCellRendererText   *cell_renderer_text,
                    const gchar           *new_text,
                    GtkFileChooserDefault *impl)
 {
-  queue_edited_idle (impl, new_text);
+ /* work around bug #154921 */
+  g_object_set (cell_renderer_text, 
+               "mode", GTK_CELL_RENDERER_MODE_INERT, NULL);
+   queue_edited_idle (impl, new_text);
 }
 
 /* Callback used from the text cell renderer when the new folder edition gets
@@ -1637,7 +1640,10 @@ static void
 renderer_editing_canceled_cb (GtkCellRendererText   *cell_renderer_text,
                              GtkFileChooserDefault *impl)
 {
-  queue_edited_idle (impl, NULL);
+ /* work around bug #154921 */
+  g_object_set (cell_renderer_text, 
+               "mode", GTK_CELL_RENDERER_MODE_INERT, NULL);
+   queue_edited_idle (impl, NULL);
 }
 
 /* Creates the widgets for the filter combo box */